package asapIs134CK.womi.client.games;

import java.util.Iterator;
import java.util.LinkedList;
import java.util.List;

import com.google.gwt.user.client.ui.Composite;



public abstract class GamePickerWidget extends Composite{
	private List<PickUpHandler> _listeners;
	
	public GamePickerWidget(){
		_listeners = new LinkedList<PickUpHandler>();
	}
	
	public void addPickupHandler(PickUpHandler handler){
		_listeners.add(handler);
	}
	protected void notifyPickUp(PickupEvent evt){
		Iterator<PickUpHandler> ite = _listeners.iterator();
		while(ite.hasNext()){
			ite.next().onPickup(evt);
		}
	}
	
}
